-
-
Notifications
You must be signed in to change notification settings - Fork 580
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve types for Y.Map's public interface #614
base: main
Are you sure you want to change the base?
Conversation
…-public-interface
@@ -74,7 +99,7 @@ export class YMap extends AbstractType { | |||
*/ | |||
_integrate (y, item) { | |||
super._integrate(y, item) | |||
;/** @type {Map<string, any>} */ (this._prelimContent).forEach((value, key) => { | |||
this._prelimContent?.forEach((value, key) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
note this logic change, but if _prelimContent
was null previously then this would have created a runtime error.
Thanks for the PR! This is on the roadmap for v14, as it is a breaking change. However, this feature is not "enough" for a new v14 release. I don't want to create too many releases for Yjs. I'll keep this PR around for now. Note: I dislike the |
Feel free to point me towards the v14 roadmap (couldn't find it with a cursory search) -- I'd be happy to assist with any other (potentially breaking) type improvements you would like to include. These are just the main type issues I'm aware of. In the meantime, I'll try to get the TS file migrated to JS and included in |
Huly®: YJS-427